<?php
class VB_Foto extends VB_Db_Table_Row implements General_Foto {
	protected $_prefix = 'foto';

	public function getFotoUrl() {
		$fotoCategory = $this->findParentRow('VB_Fotocategories');
		return IMAGEPROTOCOL . IMAGEDOMAIN . $fotoCategory->foto_category_directory .'/'. $this->foto_filename;
	}
	public function getFotoPath() {
		$fotoCategory = $this->findParentRow('VB_Fotocategories');
		return IMAGEPATH . $fotoCategory->foto_category_directory .'/'. $this->foto_filename;
	}
	
	public function getPhotoVariant($ratio, $width) {
		$photoVariants = new VB_Photo_Variants();
		$photoVariantFile = $photoVariants->getVariant($this, $ratio, $width);
		return $photoVariantFile;
	}
	
	
	
	
	
	/** Image functions **/
	
}
?>